package com.testdocs.client.project;

import com.google.gwt.user.client.rpc.RemoteService;
import com.google.gwt.user.client.rpc.RemoteServiceRelativePath;
import com.testdocs.client.error.ObjectAccessErrorException;
import com.testdocs.client.validation.ConstraintViolationException;
import com.testdocs.client.version.VersionInfo;

@RemoteServiceRelativePath("project")
public interface ProjectService extends RemoteService {
	public ProjectInfo[] getProjects() throws ObjectAccessErrorException;
	public ProjectInfo getProjectInfo(String projectId) throws ObjectAccessErrorException;
	public ProjectInfo getDefaultProject() throws ObjectAccessErrorException;
	
	public ProjectInfo createProject(ProjectInfo projectInfo, VersionInfo versionInfo) throws ObjectAccessErrorException, ConstraintViolationException;
	public ProjectInfo editProject(ProjectInfo projectInfo) throws ObjectAccessErrorException, ConstraintViolationException;
	public void removeProject(ProjectInfo projectInfo) throws ObjectAccessErrorException;
}
